<template>
  <div class="goodsdesc-container">
    <h3 class="title">{{goodsDesc.title}}</h3>
    <hr />
    <div class="content" v-html="goodsDesc.content"></div>
  </div>
</template>
<script>
export default {
  data() {
    return {
      id: this.$route.params.id,
      goodsDesc: {}
    };
  },
  created() {
    this.getGoodsDesc();
  },
  methods: {
    getGoodsDesc() {
      this.axios.get("api/goods/getdesc/" + this.id).then(response => {
        this.goodsDesc = response.data.message[0];
      });
    }
  }
};
</script>
<style lang="scss">
.goodsdesc-container {
  padding: 4px;
  .title {
    font-size: 14px;
    text-align: center;
    color: #226aff;
    margin: 15px 0;
  }
  .content {
    img {
      width: 100%;
    }
  }
}
</style>